package zjitc.service.impl;


import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;
import zjitc.dao.UserDao;
import zjitc.service.UserService;

import javax.annotation.Resource;

@Service("userService")
public class UserServiceImpl implements UserService {
    @Value("itcast")
    private String driver;
    @Autowired
    @Qualifier("userDao")
//    @Resource(name="userDao")
    private UserDao userDao;


    @Override
    public void save() {
        System.out.println(driver);
        userDao.save();
    }
}
